<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div>
        <p>圆的半径：
            <input type="text" id="r">
        </p>
        <p>圆的周长：
            <input type="text" id="cir">
        </p>
        <p>圆的面积：
            <input type="text" id="area">
        </p>
    </div>
    <script>
        var r=prompt("请输入圆的半径")
        r=parseFloat(r)&& Number(r)
        if(!isNaN(r)){
            var cir=2*Math.PI*r
            var area=Math.PI*r*r
            document.getElementById('r').value=r
            document.getElementById('cir').value=cir
            document.getElementById('area').value=area
        }
    </script>
</body>
</html>